package com.gugee.common.exception;

import lombok.Data;

/**
 * Created with IntelliJ IDEA.
 * Description:gugee产品系列的异常父类
 * User: luolifeng
 * Date: 2020-11-05 9:06
 */
@Data
public class GugeeException extends RuntimeException {
    /**
     * 异常码，用于定位发生的模块，模块之间用下划线串联
     */
    public String code;


    public GugeeException(String message, String code) {
        super(code+":"+message);
        this.code = code;
    }

    public GugeeException(String message, Throwable cause, String code) {
        super(code+":"+message, cause);
        this.code = code;
    }

}
